package com.ruoyi.project.treat.service.impl;

import com.ruoyi.project.treat.domain.TrePatient;
import com.ruoyi.project.treat.mapper.TrePatientMapper;
import com.ruoyi.project.treat.service.ITrePatientService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import java.util.List;

@Service
public class TrePatientServiceImpl implements ITrePatientService {

    @Autowired
    private TrePatientMapper trePatientMapper;

    @Override
    public TrePatient findPatient(String patiCode) {
        if (patiCode==null||patiCode.equals("")){
            return null;
        }

        TrePatient trePatient = trePatientMapper.selectPatient(patiCode);

        return trePatient;
    }

    @Override
    public List<TrePatient> findPatientList(TrePatient trePatient) {

        return trePatientMapper.selectPatientList(trePatient);
    }
}
